var login = {
    path    : "/admin/login",
    method  : "get",
    auth    : [
        function(req, next){
            if(0 === global.app.user.count)
                return next(new Error("还没有系统用户"));
            else next();
        },
        "!Sessions.user"
    ],
    next : false,
    failUrl : [
        "/admin/register",
        "/admin/index"
    ]
};

module.exports = login;
